<template>
  <div>
    <div class="model_block">
      <!-- add for 7x  -->
      <template v-for="(items, key) in channelTask2Routes">
        <h3 :key="key">{{ key }}</h3>
        <router-link v-for="route in items" :key="route.name" :to="route.path">{{ route.meta.title }}</router-link>
      </template>
    </div>
  </div>
</template>

<script>
import channelTask2 from '@/router/channelTask2'
export default {
  name: 'MenuDemo',
  components: {},
  props: {},
  data() {
    return {

    }
  },

  computed: {
    channelTask2Routes() {
      const t = {}
      channelTask2.forEach(e => {
        if (!t.hasOwnProperty(e.meta.group)) {
          t[e.meta.group] = []
        }
        t[e.meta.group].push(e)
      })
      return t
    }
  },

  methods: {}
}
</script>
<style lang='scss' scoped>
  a{
    display: block;
    line-height: 30px;

  }
   .model_block{
  display: inline-table;
 }
</style>
